<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>浮动V1</title>
<style>
    *{
        margin: 0;
        padding: 0;
    }
    article{
        width: 10rem;
        height: 10rem;
    }
    .box1{
        background-color: cyan;
        float: left;
    }
    .box2{
        background-color: purple;
        float: left;
    }
    /* 这里如果没有clear:both; 那么这个就会被第一个盖住*/
    .box3 {
        border: 2px solid cyan;
        clear: both;
    }
</style>
</head>
<body>
<article class="box1"></article>
<article class="box2"></article>
<article class="box3"></article>
</body>
</html>
